Notes/Domino Fix List
 |  |
| SPR # RSCR4XTEKW | Fixed in 5.0.10 release |  |



Product Area: Server Technical Area: Mail Server - SMTP Listener Platform: Cross Platform
SPR# RSCR4XTEKW - The SMTP listener now conforms to RFC 2821 and only accepts the CRLF character pair as a line termination sequence. Prior to this change, an LF or CR character by itself could be considered as a line terminator.
Technote Number: 1096192

Problem:
This issue was reported to Quality Engineering and has been addressed in Domino
5.0.10.
Excerpt from the Lotus Notes and Domino Release 5.0.10 MR fix list (available
at http://www.lotus.com/ldd):
Mail Server - SMTP Listener
SPR# RSCR4XTEKW - The SMTP listener now conforms to RFC 2821 and only accepts
the CRLF character pair as a line termination sequence. Prior to this change,
an LF or CR character by itself could be considered as a line terminator.
Starting with Domino 5.0.10, the following NOTES.INI parameter can be used to
revert this behavior:
SMTPNonStandardLineTermination=1
Supporting Information:
An older SMTP system sends a message to a Domino 5.x SMTP server. The message
contains the following text:
This is a
test
.
More
The initial text of the message, "This is a test", is accepted by the receiving
Domino SMTP server as the complete body of the message. The single period (.),
preceded by a "<CR>" and followed by a "<CRLF>", is interpreted by the Domino
SMTP server as a cue to terminate the DATA stage. The Domino SMTP server
interprets the word "More", the latter portion of the intended message, as
being an invalid command. When the final period is sent by the sending SMTP
server to designate the end of the DATA stage (after the word "More" is sent),
the receiving Domino SMTP server interprets that period as another invalid
command.
Note: When transferring the data of the message, the sending SMTP server does
not embed the first period (.) between two "<CRLF>" characters; instead, it
sends the "<CR>.<CRLF>" characters. It does not intend the period (.) to be
interpreted as part of an end-of-data cue. The receiving Domino SMTP server,
however, interprets "<CR>.<CRLF>" as end-of-data characters.
The following output, captured in LOG.NSF, records the transfer of data between
both SMTP servers, starting with the DATA command issued by the sending server.
[02E0:0004-08BC] R: DATA
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] Processing in Connected state
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] DATA command received
<Date> 10:33:02.32 AM [02E0:0004-08BC] SMTP CITask StateMachine> Sent 53 bytes
to <IP Address1>
[02E0:0004-08BC] S: 354 Enter message, end with "." on a line by itself<CRLF>
<Date> 10:33:02.47 AM [02E0:0004-08BC] SMTP CITask StateMachine> Received total
of 9 lines, 185 bytes from <IP Address1>
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] Processing in Connected state
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] DATA command (cont.)
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] RFC822 message stream saved to
D:\DOCUME~1\seggen\LOCALS~1\Temp\st617518.TMP
<Date> 10:33:02 AM SMTP Server: Message 003476A8 received
<Date> 10:33:02.61 AM [02E0:0004-08BC] SMTP CITask StateMachine> Sent 35 bytes
to <IP Address1>
[02E0:0004-08BC] S: 250 Message accepted for delivery<CRLF>
<Date> 10:33:02.65 AM [02E0:0004-08BC] SMTP CITask StateMachine> Received 4
bytes from <IP Address1>
[02E0:0004-08BC] R: More
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] Processing in Connected state
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] Invalid command received
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] 500 Syntax error, command
"More" unrecognized
<Date> 10:33:02.68 AM [02E0:0004-08BC] SMTP CITask StateMachine> Sent 47 bytes
to <IP Address1>
[02E0:0004-08BC] S: 500 Syntax error, command "More" unrecognized<CRLF>
<Date> 10:33:02.69 AM [02E0:0004-08BC] SMTP CITask StateMachine> Received 1
bytes from <IP Address1>
[02E0:0004-08BC] R: .
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] Processing in Connected state
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] Invalid command received
<Date> 10:33:02 AM SMTP Server [02E0:0004-08BC] 500 Syntax error, command "."
unrecognized
<Date> 10:33:02.72 AM [02E0:0004-08BC] SMTP CITask StateMachine> Sent 44 bytes
to <IP Address1>
[02E0:0004-08BC] S: 500 Syntax error, command "." unrecognized<CRLF>
<Date> 10:33:02.73 AM [02E0:0004-08BC] SMTP CITask RecvErrorHandler> ERROR:
(<IP Address1>) Receive failed (did not timeout), error = 0A02h (Remote system
no longer responding)
<Date> 10:33:02 AM SMTP Server: <IP Address1> disconnected. 1 message[s]
received
<Date> 10:33:04 AM Router: Transferring mail to domain RITZ.ACME.COM (host
RITZ.ACME.COM )
via SMTP<Date> 10:33:05 AM Router: Transferred 1 messages to RITZ.ACME.COM
(host RITZ.ACME.COM) via SMTP
<Date> 10:33:07 AM Router: Message 003476A8 transferred to RITZ.ACME.COM for
juser@acme.com via SMTP
2.3.7 Lines
SMTP commands and, unless altered by a service extension, message data, are
transmitted in "lines". Lines consist of zero or more data characters
terminated by the sequence ASCII character "CR" (hex value 0D) followed
immediately by ASCII character "LF" (hex value 0A).
This termination sequence is denoted as <CRLF> in this document. Conforming
implementations MUST NOT recognize or generate any other character or character
sequence as a line terminator. Limits MAY be imposed on line lengths by
servers (see section 4.5.3).
In addition, the appearance of "bare" "CR" or "LF" characters in text i.e.,
either without the other) has a long history of causing problems in mail
implementations and applications that use the mail system as a tool. SMTP
client implementations MUST NOT transmit these characters except when they are
intended as line terminators and then MUST, as indicated above, transmit them
only as a <CRLF> sequence.
4.1.1.4 DATA
The mail data is terminated by a line containing only a period, that is, the
character sequence "<CRLF>.<CRLF>" (see section 4.5.2). This is the end of
mail data indication. Note that the first <CRLF> of this terminating sequence
is also the <CRLF> that ends the final line of the data (message text) or, if
there was no data, ends the DATA command itself. An extra <CRLF> MUST NOT be
added, as that would cause an empty line to be added to the message. The only
exception to this rule would arise if the message body were passed to the
originating SMTP-sender with a final "line" that did not end in <CRLF>; in that
case, the originating SMTP system MUST either reject the message as invalid or
add <CRLF> in order to have the receiving SMTP server recognize the "end of
data" condition.
4.5.2 Transparency
Without some provision for data transparency, the character sequence
"<CRLF>.<CRLF>" ends the mail text and cannot be sent by the user.
In general, users are not aware of such "forbidden" sequences. To allow all
user composed text to be transmitted transparently, the following procedures
are used:
- Before sending a line of mail text, the SMTP client checks the first
character of the line. If it is a period, one additional period is inserted at
the beginning of the line.
- When a line of mail text is received by the SMTP server, it checks the line.
If the line is composed of a single period, it is treated as the end of mail
indicator. If the first character is a period and there are other characters
on the line, the first character is deleted.
Related Documents:
Using TELNET to Troubleshoot Link to SMTP
Document #: 150231
What are Some Syntax Errors That Can Occur During a Telnet Session ?
Document #: 1101994 More >


Last Modified on 05/22/2007
Go back
 |